from sqlalchemy import create_engine
import tushare as ts

sts=ts.get_stock_basics();
engine = create_engine('postgresql://lengdh:123456@127.0.0.1:5432/postgres')
#追加数据到现有表
sts.to_sql('stocks',engine,if_exists='append')